CC := gcc
CFLAGS := -Wall -I../ -I/usr/realtime/include
LDFLAGS := -L../ -L/usr/realtime/lib -llxrt

all: load_pdo_config

load_pdo_config: load_pdo_config.o rtai_shmem.o
	$(CC) -o $@ $^ $(LDFLAGS)

load_pdo_config.o: load_pdo_config.c
	$(CC) $(CFLAGS) -c $<

rtai_shmem.o: ../rtai_shmem.c
	$(CC) $(CFLAGS) -c $< -o $@

clean:
	rm -f load_pdo_config *.o

.PHONY: all clean
